#ifndef List
#define List

#include <iostream>

typedef struct node {
    int data;
    struct node *next;
}NODE;

class LinkList
{
private:
    NODE *head;
public:
    LinkList() { head = NULL; }
    ~LinkList();
    bool clearSqList();
    bool isEmpty() { return head == NULL; }
    int Length();
    bool GetElem(int i, int *e);
    int LocateElem(int e);
    bool PriorElem(int cur_e, int *pre_e);
    bool NextElem(int cur_e, int *next_e);
    bool Insert(int i, int e);
    bool Delete(int i, int *e);
    NODE * Reverse();
};

#endif // !List

